﻿namespace Contoso.ActiveDirectory {

    #region Usings
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.DirectoryServices;
    using System.Diagnostics;
    using System.Threading;
    #endregion

    /// <summary>
    /// The NTDSSettings object is a child of a Server object within an AD Site object
    /// The NTDSSettings object is also known as nTDSDSARO for a read-only domain controller.
    /// </summary>
    [Serializable]
    public class NTDSSettingsRO : NTDSSettings {

        #region Members
        public new static readonly string ObjectCategoryShortName = "nTDSDSARO";
        #endregion

        #region Constructors
        public NTDSSettingsRO() {
            this.Initialize();
        }
        public NTDSSettingsRO(DirectoryEntry directoryEntry, bool destroyInputObject = true)
            : base(directoryEntry, destroyInputObject) {
            if (this.GetType().Name == typeof(NTDSSettingsRO).Name) {
                this.Attributes = null;
            }
        }

        public NTDSSettingsRO(SearchResult result, bool destroyInputObject = true)
            : base(result, destroyInputObject) {
            if (this.GetType().Name == typeof(NTDSSettingsRO).Name) {
                this.Attributes = null;
            }
        }

        public NTDSSettingsRO(List<string> ldifOutput)
            : base(ldifOutput) {
            if (this.GetType().Name == typeof(NTDSSettingsRO).Name) {
                this.Attributes = null;
            }
        }
        #endregion
    }
}